package com.moyingren.springcloud.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;

import javax.annotation.Resource;

@Configuration
public class Security {
    @Resource
    public void configGlobal(AuthenticationManagerBuilder auth) throws Exception {
        auth.inMemoryAuthentication().withUser("actuator").password("123456")
                .roles("USER", "ACTUATOR");
    }
}
